﻿@using SCMS.CoreBusinessLogic.NotificationsManager
@using SCMS.Resources
@model SCMS.UI.Models.DocPreparer
@{AjaxOptions ajaxOpts = new AjaxOptions
  {
      UpdateTargetId = "tabs-9",
      LoadingElementId = "loading",
      HttpMethod = "Post",
      Url = Url.Action("SaveDocPreparer"),
      OnSuccess = "CloseDialog();"
  };}

<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>

@using (Ajax.BeginForm(null, null, ajaxOpts, new { @class = "form" }))
{
    @Html.ValidationSummary(true)
    <table>
        <tbody>            
            <tr>
                <td align="right">@Resources_frank.Budget_CreateDocPreparer_Preparer<font color="red">*</font>:</td>
                <td>
                    @Html.DropDownListFor(model => model.PreparerId, Model.StaffList, Resources_frank.Global_String_PleaseSelect)<br />
                    @Html.ValidationMessageFor(model => model.PreparerId, Resources_frank.Global_String_Required)
                    @Html.HiddenFor(model => model.EntityDocPreparer.ProjectDonorId)
                    @Html.HiddenFor(model => model.EntityDocPreparer.DocumentCode)
                </td>
            </tr>
            <tr>
                <td></td>
                <td>                    
                    <input type="submit" value=" @Resources_frank.Global_String_Save " class="btn green" />&nbsp;
                    <input type="button" value="@Resources_frank.Global_String_Cancel" class="btn green" onclick="javascript:CloseDialog()" />
                </td>
            </tr>
         </tbody>
    </table>
}